package com.nami.message.app.grpmsg;

import com.nami.message.app.convertor.GrpCmd2DomainConvertor;
import com.nami.message.domain.service.GrpMsgDomainService;
import com.nami.message.facade.grpmsg.GrpMsgAddFacade;
import com.nami.message.facade.grpmsg.request.GrpMsgAddCmd;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;


@Slf4j
@Service
@RequiredArgsConstructor
public class GrpMsgAddFacadeImpl implements GrpMsgAddFacade {

    private final GrpMsgDomainService msgDomainService;

    @Override
    public void execute(GrpMsgAddCmd cmd) {
//        try {
        msgDomainService.processReceivedMessage(GrpCmd2DomainConvertor.toDomain(cmd));
//        } catch (Exception var3) {
//            var3.printStackTrace();
//        }
    }

}
